
#pragma once

class CEntityView : public CWnd 
{
// Construction
public:

	bool                  m_OgreInitialised;
    bool                  m_UpdateNeeded;
	//AnimationState*  mAnimStates;
	CEntityView() {};
	virtual ~CEntityView() {};
	void     SetupOgre();
	void     LoadEditorObjects();
	void     TerminateOgre();
	void     AdjustCamera();
	void     DisplayMesh(String name);

	bool frameStarted();
	afx_msg void OnPaint();
protected:
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);

	afx_msg void OnSize(UINT nType, int cx, int cy);
	afx_msg BOOL OnEraseBkgnd(CDC* pDC);
	DECLARE_MESSAGE_MAP()
};


class CAddEntityWnd : public CDockablePane
{
// Construction
public:
	CAddEntityWnd();

// Attributes
public:
    CListBox    m_wndList;
	CEntityView m_wndEntityView;
	CButton     m_AddButton;
	CFont       m_Font;
	CString     m_SelectedEntity;

    void SetUpdateNeeded(bool value) {m_wndEntityView.m_UpdateNeeded = value;};
    bool GetUpdateNeeded() {return m_wndEntityView.m_UpdateNeeded;};
    //RenderWindow *GetRenderWindow() {return m_wndEntityView.m_Window;};
protected:

// Implementation
public:
	virtual ~CAddEntityWnd();
	afx_msg void OnSelectionChanged();

protected:
	afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
	afx_msg void OnSize(UINT nType, int cx, int cy);
	afx_msg void OnClose();
	afx_msg void OnAddToSceneClick();
	afx_msg void OnUpdateAddBtn(CCmdUI *pCmdUI);
	DECLARE_MESSAGE_MAP()
};

